package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.TbAlertLogMapper;
import com.ruoyi.system.domain.TbAlertLog;
import com.ruoyi.system.service.ITbAlertLogService;

/**
 * 事故Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-12-10
 */
@Service
public class TbAlertLogServiceImpl implements ITbAlertLogService 
{
    @Autowired
    private TbAlertLogMapper tbAlertLogMapper;

    /**
     * 查询事故
     * 
     * @param alertId 事故主键
     * @return 事故
     */
    @Override
    public TbAlertLog selectTbAlertLogByAlertId(String alertId)
    {
        return tbAlertLogMapper.selectTbAlertLogByAlertId(alertId);
    }

    /**
     * 查询事故列表
     * 
     * @param tbAlertLog 事故
     * @return 事故
     */
    @Override
    public List<TbAlertLog> selectTbAlertLogList(TbAlertLog tbAlertLog)
    {
        return tbAlertLogMapper.selectTbAlertLogList(tbAlertLog);
    }

    /**
     * 新增事故
     * 
     * @param tbAlertLog 事故
     * @return 结果
     */
    @Override
    public int insertTbAlertLog(TbAlertLog tbAlertLog)
    {
        return tbAlertLogMapper.insertTbAlertLog(tbAlertLog);
    }

    /**
     * 修改事故
     * 
     * @param tbAlertLog 事故
     * @return 结果
     */
    @Override
    public int updateTbAlertLog(TbAlertLog tbAlertLog)
    {
        return tbAlertLogMapper.updateTbAlertLog(tbAlertLog);
    }

    /**
     * 批量删除事故
     * 
     * @param alertIds 需要删除的事故主键
     * @return 结果
     */
    @Override
    public int deleteTbAlertLogByAlertIds(String[] alertIds)
    {
        return tbAlertLogMapper.deleteTbAlertLogByAlertIds(alertIds);
    }

    /**
     * 删除事故信息
     * 
     * @param alertId 事故主键
     * @return 结果
     */
    @Override
    public int deleteTbAlertLogByAlertId(String alertId)
    {
        return tbAlertLogMapper.deleteTbAlertLogByAlertId(alertId);
    }
}
